package com.jingdianjichi.oss.enums;

import lombok.Getter;

/**
 * ClassName:AuthUserStatusEnum
 * Package:com.jingdianjichi.auth.common.enums
 * Description:
 *
 * @Author fst
 * @Create 2024/10/10 14:19
 * @Version 1.0
 */

@Getter
public enum AuthUserStatusEnum
{
    OPEN(0,"启用"),CLOSE(1,"禁用");



    private Integer code;
    private String desc;

     AuthUserStatusEnum(int code,String desc)
    {
        this.code=code;
        this.desc=desc;
    }

    public static AuthUserStatusEnum getByCode(Integer codeVal)
    {
        for (AuthUserStatusEnum authUserStatusEnum : AuthUserStatusEnum.values()) {
            if(authUserStatusEnum.code==codeVal)
            {
                return authUserStatusEnum;
            }
        }
        return null;
    }
}
